<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<title>车还还</title>
		<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
		<link rel="stylesheet" type="text/css" href="/Public/css/main.css"/>
		<link rel="stylesheet" type="text/css" href="/Public/weixin/css/bind.css"/>
		<script type="text/javascript" src="/Public/js/jquery/jquery-1.11.3.min.js" ></script>
		<style>
			.tl-list{margin:0.5rem 1.0rem;}
			.tl-list ul li{margin: 0 0.5rem;padding:0.5rem 0;border-bottom: 1px dashed grey;overflow:hidden;}
			.tl-list ul li .left{float:left;width:25%;}
			.tl-list .user-ico{width:4rem;border-radius: 50%;}
			.tl-list .star-wrap{position: absolute;bottom:0.5rem;left:2.5rem;}
			.tl-list .star-wrap img {width:1.5rem;}
			.tl-list ul li .mid{float:left;width:60%;}
			.tl-list ul li .right-input{float:left;border:none;}
			.tl-list ul li .right-button{float:right;background:#ff5700;color:#fff;border-radius:5px;padding: 5px 10px;}
			.tl-list ul .remark {padding: 10px 0;text-align: center;color:#ff5700;}
			.tl-sub{margin:0.5rem 1.0rem;}
			.tl-sub #sub{background:#ff5700;padding:0.5rem 0;text-align:center;color:#fff;}
		</style>
	</head>
	
	<body >
		<section class="tl-list">
			<ul>
				<li>
					<div class="left" style="position:relative;">
		 			<img src="{$user['headimgurl']}" class="user-ico"/>
		 			<span class="star-wrap"><img src="/Public/images/weixin/star.png"></span>
		 			</div>
		 			<span class="mid" style="line-height: 4rem;font-weight:bold;">{$user['nickname']}</span>
		 			<i class="am-icon-angle-right am-icon-md list-pr"></i>
				</li>
				<li > 			
		 			<span class="left">姓名:</span>
		 			<input type="text" class="right-input" id="name" name='name' value="{$user['name']}" placeholder="请输入姓名" />
				</li>
				<li > 			
		 			<span class="left">证件号码:</span>
		 			<input type="text" class="right-input" id="card" name='card' value="{$user['card']}" placeholder="请输入证件号码" />
				</li>
				<li > 			
		 			<span class="left">e&nbsp;账号:</span>
		 			<input type="text" class="right-input" id="eaccount" value="{$user['eaccount']}" name='eaccount' placeholder="请输入e账号" />
				</li>
				<li > 			
		 			<span class="left">手机号码:</span>
		 			<input type="text" class="right-input" name='phone' value="{$user['mobile']}" id="phone" placeholder="请输入手机号码" />
				</li>
				<div id='remark' class='remark'></div>
			</ul>
		</section>
		<!--/end修改手机-->
	
	<section class="tl-sub">
		<div id='sub' onclick='sub();'>修改</div>
	</section>
	</body>
  <script>

  	//提交
  	function sub(){
  		var name = $('#name').val();
  		var card = $('#card').val();
  		var eaccount = $('#eaccount').val();
  		var phone = $('#phone').val();
  		console.log(card);
  		$.post('/Weixin/User/person',
  		{
  			name:name,
  			card:card,
  			eaccount:eaccount,
  			phone:phone
  		},function(data){
  			var list = new Array();
		  	list = eval('(' + data +')');
		  	if(list['returnCode'] == 0){
		  		window.location.href = list['returnUrl'];
		  	}else{
		  		$('#remark').html(list['returnInfo']);
		  	}	
  		});
  	}
  </script>
  </html>
